<template>
  <div>
    <h2>谁点的歌{{ name }}</h2>
    <p>{{ id }}</p>
    <ul>
      <li v-for="item in this.list" :key="item">{{ item }}</li>
    </ul>
  </div>
</template>

<script>
export default {
  name: "Music",
  // 只要在
  props: ["name", "id"],
  computed: {
    list() {
      switch (this.id) {
        case 1:
          return ["背对背拥抱", "小酒窝", "修炼爱情"];
        case 2:
          return ["雅俗共赏", "素颜", "画皮"];
        default:
          return [];
      }
    },
  },
};
</script>

<style>
</style>